<template>
  <div class="go-back">
    <el-page-header @back="goBack" v-bind="$attrs">
      <template #[key] v-for="(item, key) in $slots">
        {{ item[0].text }}
      </template>
    </el-page-header>
  </div>
</template>
<script>
export default {
  name: 'goBack',
  methods: {
    goBack() {
      this.$router.go(-1)
      this.$emit('click')
    }
  }
}
</script>
<style lang="scss" scoped>
.go-back {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
}
/deep/.el-page-header__left {
  border: 0;
  margin: 0;
  color: var(--text-color);
  &::after {
    content: '';
    display: none;
  }
}
</style>
